123456789101112131415161718192021222324252627282930313233343536373839404142434445(**************************************************************************)(* *)(* OCaml *)(* *)(* Xavier Leroy, projet Cristal, INRIA Rocquencourt *)(* *)(* Copyright 1997 Institut National de Recherche en Informatique et *)(* en Automatique. *)(* *)(* All rights reserved. This file is distributed under the terms of *)(* the GNU Lesser General Public License version 2.1, with the *)(* special exception on linking described in the file LICENSE. *)(* *)(**************************************************************************)(* Auxiliary type for reporting syntax errors *)typeerror=UnclosedofLocation.t*string*Location.t*string|ExpectingofLocation.t*string|Not_expectingofLocation.t*string|Applicative_pathofLocation.t|Variable_in_scopeofLocation.t*string|OtherofLocation.t|Ill_formed_astofLocation.t*string|Invalid_package_typeofLocation.t*string|Removed_string_setofLocation.texceptionErroroferrorexceptionEscape_errorletlocation_of_error=function|Unclosed(l,_,_,_)|Applicative_pathl|Variable_in_scope(l,_)|Otherl|Not_expecting(l,_)|Ill_formed_ast(l,_)|Invalid_package_type(l,_)|Expecting(l,_)|Removed_string_setl->lletill_formed_astlocs=raise(Error(Ill_formed_ast(loc,s)))