add isinstance static type checking for jit (#15076)
authorWanchao Liang <wanchaol@users.noreply.github.com>
Mon, 17 Dec 2018 23:18:51 +0000 (15:18 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Mon, 17 Dec 2018 23:21:49 +0000 (15:21 -0800)
commitc5dd91c4aeb6184dd1e11943385da72f75a1e2f1
tree2ae8094524bf52945b21409614cb60d1a87e8eb9
parent216ab259fb5142c20c9e5aef74accb4fe112858a
add isinstance static type checking for jit (#15076)

Summary:
This PR add isinstance to do static type checking in JIT.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/15076

Differential Revision: D13471067

Pulled By: wanchaol

fbshipit-source-id: d39b7ed5db9fcca4b503659d02cf7795950ea8ea
test/test_jit.py
torch/csrc/jit/script/compiler.cpp
torch/csrc/jit/script/compiler.h