~ubuntu-branches/debian/sid/ocaml/sid

« back to all changes in this revision

Viewing changes to parsing/syntaxerr.ml

  • Committer: Bazaar Package Importer
  • Author(s): Stéphane Glondu
  • Date: 2011-04-21 21:35:08 UTC
  • mfrom: (1.1.11 upstream) (12.1.14 sid)
  • Revision ID: james.westby@ubuntu.com-20110421213508-kg34453aqmb0moha
* Fixes related to -output-obj with g++ (in debian/patches):
  - add Declare-primitive-name-table-as-const-char
  - add Avoid-multiple-declarations-in-generated-.c-files-in
  - fix Embed-bytecode-in-C-object-when-using-custom: the closing
    brace for extern "C" { ... } was missing in some cases

Show diffs side-by-side

added added

removed removed

Lines of Context:
10
10
(*                                                                     *)
11
11
(***********************************************************************)
12
12
 
13
 
(* $Id: syntaxerr.ml 8705 2007-12-04 13:38:58Z doligez $ *)
 
13
(* $Id: syntaxerr.ml 9316 2009-07-15 14:06:37Z xleroy $ *)
14
14
 
15
15
(* Auxiliary type for reporting syntax errors *)
16
16
 
18
18
 
19
19
type error =
20
20
    Unclosed of Location.t * string * Location.t * string
 
21
  | Applicative_path of Location.t
21
22
  | Other of Location.t
22
23
 
23
24
exception Error of error
35
36
        fprintf ppf "%aThis '%s' might be unmatched"
36
37
          Location.print_error opening_loc opening
37
38
      end
 
39
  | Applicative_path loc ->
 
40
      fprintf ppf "%aSyntax error: applicative paths of the form F(X).t are not supported when the option -no-app-func is set."
 
41
        Location.print_error loc
38
42
  | Other loc ->
39
43
      fprintf ppf "%aSyntax error" Location.print_error loc