solved some TODOs about Tgeneric type arguments (2)
[hiphop-php.git] / hphp / hack / src / typing / nast_check / read_from_append_check.ml
blobf380c57ef62a46d863aa37d1af04217c67e357a3
1 (*
2 * Copyright (c) 2018, Facebook, Inc.
3 * All rights reserved.
5 * This source code is licensed under the MIT license found in the
6 * LICENSE file in the "hack" directory of this source tree.
8 *)
10 open Aast
11 open Nast_check_env
13 let handler =
14 object
15 inherit Nast_visitor.handler_base
17 method! at_expr env s =
18 match snd s with
19 | Array_get ((p, _), None) when not env.array_append_allowed ->
20 Errors.reading_from_append p
21 | _ -> ()
22 end