summaryrefslogtreecommitdiffstats
path: root/otherlibs/labltk/compiler
diff options
context:
space:
mode:
Diffstat (limited to 'otherlibs/labltk/compiler')
-rw-r--r--otherlibs/labltk/compiler/compile.ml2
-rw-r--r--otherlibs/labltk/compiler/tables.ml6
2 files changed, 4 insertions, 4 deletions
diff --git a/otherlibs/labltk/compiler/compile.ml b/otherlibs/labltk/compiler/compile.ml
index e20a666a7..25cf3be81 100644
--- a/otherlibs/labltk/compiler/compile.ml
+++ b/otherlibs/labltk/compiler/compile.ml
@@ -151,7 +151,7 @@ let ppMLtype ?(any=false) ?(return=false) ?(def=false) ?(counter=ref 0) =
end) ^ "]"
with
Not_found -> prerr_endline ("ppMLtype " ^ s ^ " ?"); s
- else if not def & List.length typdef.constructors > 1 then
+ else if not def && List.length typdef.constructors > 1 then
"#" ^ s
else s
else s
diff --git a/otherlibs/labltk/compiler/tables.ml b/otherlibs/labltk/compiler/tables.ml
index d6eac7c2b..f5fc1435c 100644
--- a/otherlibs/labltk/compiler/tables.ml
+++ b/otherlibs/labltk/compiler/tables.ml
@@ -160,7 +160,7 @@ let new_type typname arity =
(* Assume that types not yet defined are not subtyped *)
(* Widget is builtin and implicitly subtyped *)
let is_subtyped s =
- s = "widget" or
+ s = "widget" ||
try
let typdef = Hashtbl.find types_table s in
typdef.subtypes <> []
@@ -312,7 +312,7 @@ let enter_type typname ?(variant = false) arity constructors =
end;
(* Callbacks require widget context *)
typdef.requires_widget_context <-
- typdef.requires_widget_context or
+ typdef.requires_widget_context ||
has_callback c.template
end
@@ -336,7 +336,7 @@ let enter_subtype typ arity subtyp constructors =
typdef.constructors <- c :: typdef.constructors
end;
typdef.requires_widget_context <-
- typdef.requires_widget_context or
+ typdef.requires_widget_context ||
has_callback c.template;
c
| Abbrev name -> find_constructor name typdef.constructors