Skip to content

Commit 9afaace

Browse files
committed
Fix build error regarding missing types in torch::jit
This commit adds include statements of the file `torch/csrc/jit/ir/ir.h` for files that use types from torch::jit. Fixes #506
1 parent ccfdfd1 commit 9afaace

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

python/torch_mlir/dialects/torch/importer/jit_ir/csrc/class_annotator.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@
2323
#ifndef TORCHMLIRJITIRIMPORTER_CSRC_CLASS_ANNOTATOR_H
2424
#define TORCHMLIRJITIRIMPORTER_CSRC_CLASS_ANNOTATOR_H
2525

26+
#include <torch/csrc/jit/ir/ir.h>
27+
2628
#include "pybind.h"
2729

2830
namespace torch_mlir {

python/torch_mlir/dialects/torch/importer/jit_ir/csrc/get_registered_ops.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99

1010
#include "get_registered_ops.h"
1111

12+
#include <torch/csrc/jit/ir/ir.h>
13+
1214
namespace py = pybind11;
1315

1416
static const char kGetRegisteredOpsDocstring[] =

0 commit comments

Comments
 (0)