Commit f4b123a8 authored by POGODALLA Sylvain's avatar POGODALLA Sylvain

Changes in the directory structure

parent 26f58363
......@@ -301,7 +301,7 @@ on `(hostname || uname -n) 2>/dev/null | sed 1q`
"
# Files that config.status was made for.
config_files=" ./Makefile config/Makefile src/Makefile.master src/Makefile.common src/Makefile src/utils/Makefile src/grammars/Makefile src/lambda/Makefile"
config_files=" ./Makefile config/Makefile src/Makefile.master src/Makefile.common src/Makefile src/utils/Makefile src/grammars/Makefile src/lambdas/Makefile"
ac_cs_usage="\
\`$as_me' instantiates files from templates according to the
......@@ -416,7 +416,7 @@ do
"src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
"src/utils/Makefile") CONFIG_FILES="$CONFIG_FILES src/utils/Makefile" ;;
"src/grammars/Makefile") CONFIG_FILES="$CONFIG_FILES src/grammars/Makefile" ;;
"src/lambda/Makefile") CONFIG_FILES="$CONFIG_FILES src/lambda/Makefile" ;;
"src/lambdas/Makefile") CONFIG_FILES="$CONFIG_FILES src/lambdas/Makefile" ;;
*) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
......
......@@ -117,7 +117,7 @@ AC_SUBST(OCAMLP4_LOC)
AC_SUBST(SET_MAKE)
AC_CONFIG_FILES([./Makefile config/Makefile src/Makefile.master src/Makefile.common src/Makefile src/utils/Makefile src/grammars/Makefile src/lambda/Makefile])
AC_CONFIG_FILES([./Makefile config/Makefile src/Makefile.master src/Makefile.common src/Makefile src/utils/Makefile src/grammars/Makefile src/lambdas/Makefile])
AC_PROG_MAKE_SET
......
......@@ -2123,7 +2123,7 @@ echo "${ECHO_T}Compilation will be done with the $OCAML09WARNINGS option" >&6; }
ac_config_files="$ac_config_files ./Makefile config/Makefile src/Makefile.master src/Makefile.common src/Makefile src/utils/Makefile src/grammars/Makefile src/lambda/Makefile"
ac_config_files="$ac_config_files ./Makefile config/Makefile src/Makefile.master src/Makefile.common src/Makefile src/utils/Makefile src/grammars/Makefile src/lambdas/Makefile"
{ echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
......@@ -2731,7 +2731,7 @@ do
"src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
"src/utils/Makefile") CONFIG_FILES="$CONFIG_FILES src/utils/Makefile" ;;
"src/grammars/Makefile") CONFIG_FILES="$CONFIG_FILES src/grammars/Makefile" ;;
"src/lambda/Makefile") CONFIG_FILES="$CONFIG_FILES src/lambda/Makefile" ;;
"src/lambdas/Makefile") CONFIG_FILES="$CONFIG_FILES src/lambdas/Makefile" ;;
*) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
......
PHONY: test
SUBDIRS= utils grammars lambda
SUBDIRS= utils grammars lambdas
test:
$(foreach dir,$(SUBDIRS),$(MAKE) -r -S -C $(dir) byte;)
......
PHONY: test
SUBDIRS= utils grammars lambda
SUBDIRS= utils grammars lambdas
test:
$(foreach dir,$(SUBDIRS),$(MAKE) -r -S -C $(dir) byte;)
......
......@@ -24,7 +24,7 @@ LIBDIR = -I +dypgen -I +camlp4
PREVIOUS_DIRS = ../utils
# Source files in the right order of dependance
ML = error.ml abstract_syntax.ml typechecker.ml entry.ml parser.ml lexer.ml
ML = error.ml abstract_syntax.ml entry.ml parser.ml lexer.ml
EXE_SOURCES = test.ml
####################################
......
......@@ -74,7 +74,6 @@
let empty_sig = Abstract_sig.empty ""
let set e (s,_) = Entry.set e s
}
......
let options = []
let usg_msg = ""
let parse filename =
let in_ch = open_in filename in
let lexbuf = Lexing.from_channel in_ch in
try(
let sgs = fst (List.hd (Parser.signatures Lexer.lexer lexbuf)) in
List.iter (fun sg ->
let x = Printf.printf "%s\n"
(Abstract_syntax.Abstract_sig.to_string sg)
in
Printf.printf "\n\n" ;
print_string "\nResultat typecheck : \n";
let Abstract_syntax.Abstract_sig.Signature(name,y) = sg in
let t =
(Typechecker.typecheck
(name,y)) in
let Abstract_syntax.Abstract_typ.Signature
(name,size,_,trie,content) = t in
let list_decl = Tries.Tries.content trie in
print_string "[";
List.iter
(fun x -> (match x with
Abstract_syntax.Abstract_typ.Term_def(s,i,kd,wf,typ) ->
print_string (s^" = ");
Typechecker.display_wfterm t wf;
print_string " : ";
Typechecker.display_typ_tdef t typ;
print_string " ;\n ";
| Abstract_syntax.Abstract_typ.Term_decl(s,i,kd,typ) ->
print_string (s^" : ");
Typechecker.display_typ_tdef t typ;
print_string " ;\n ";
| Abstract_syntax.Abstract_typ.Type_def(s,i,typ) ->
print_string (s^" : ");
Typechecker.display_typ_tdef t typ;
print_string " ;\n ";
| Abstract_syntax.Abstract_typ.Type_decl
(s,i,Abstract_syntax.Abstract_typ.K tdl) ->
print_string (s^" : K[");
List.iter (Typechecker.display_typ_tdef t) tdl;
print_string "] ;\n ";))
list_decl;
print_string"]\n";
x) sgs)
with
| Error.Error e -> Printf.fprintf stderr "Error: %s\n" (Error.error_msg e lexbuf "test.dat")
| Dyp.Syntax_error -> Printf.fprintf stderr "Dyp: %s\n" (Error.error lexbuf "test.dat")
let () = Arg.parse options parse usg_msg
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment