summaryrefslogtreecommitdiffstats
path: root/src/global_checks.ml
diff options
context:
space:
mode:
Diffstat (limited to 'src/global_checks.ml')
-rw-r--r--src/global_checks.ml6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/global_checks.ml b/src/global_checks.ml
index a63e652..4a97221 100644
--- a/src/global_checks.ml
+++ b/src/global_checks.ml
@@ -174,7 +174,7 @@ let is_global_var context ident =
| _ -> false)
| I_hash ->
(match ident with
- | "ENV" | "SIG" -> true
+ | "ENV" | "SIG" | "INC" -> true
| _ -> false)
| I_star ->
(match ident with
@@ -183,7 +183,7 @@ let is_global_var context ident =
| _ -> false)
| I_func ->
(match ident with
- | "-b" | "-c" | "-d" | "-e" | "-f" | "-l" | "-r" | "-s" | "-w" | "-x"
+ | "-b" | "-c" | "-d" | "-e" | "-f" | "-l" | "-r" | "-s" | "-w" | "-x" | "-z" | "-t"
| "abs" | "alarm" | "atan2" | "bless"
| "caller" | "chdir" | "chmod" | "chomp" | "chop" | "chown" | "chr" | "chroot" | "close" | "closedir" | "cos" | "crypt"
| "defined" | "delete" | "die"
@@ -399,7 +399,7 @@ let check_variables vars t =
| Call_op("if infix", [List [My_our _]; List [Num("0", _)]], _) -> None (* special allowed case *)
| Call_op(op, List (My_our _ :: _) :: _, pos)
- | Call_op(op, My_our _ :: _, pos)
+ | Call_op(op, My_our("my", _, _) :: _, pos)
| Call_op(op, Call_op("local", _, _) :: _, pos) ->
if op <> "=" then warn_with_pos [Warn_traps] pos (sprintf "applying %s on a new initialized variable is wrong" op);
None