# Module cannot see defines defined in pkg, if this pkg is imported inside module. What is the reason for it?

**URL:** <https://verificationacademy.com/forums/t/module-cannot-see-defines-defined-in-pkg-if-this-pkg-is-imported-inside-module-what-is-the-reason-for-it/40991>\
**Category:** SystemVerilog\
**Tags:** SystemVerilog, Package, module, package-inside-module\
**Created:** [November 9, 2022, 1:44pm UTC](https://verificationacademy.com/forums/t/module-cannot-see-defines-defined-in-pkg-if-this-pkg-is-imported-inside-module-what-is-the-reason-for-it/40991 "2022-11-09T13:44:45Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Elene](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/e/dfb087/32.png) [@Elene](https://verificationacademy.com/forums/u/Elene)\
**Post date:** [November 9, 2022, 2:49pm UTC](https://verificationacademy.com/forums/t/module-cannot-see-defines-defined-in-pkg-if-this-pkg-is-imported-inside-module-what-is-the-reason-for-it/40991/3 "2022-11-09T14:49:32Z")

</div>

_In reply to [cgales](https://verificationacademy.com/forums/t/module-cannot-see-defines-defined-in-pkg-if-this-pkg-is-imported-inside-module-what-is-the-reason-for-it/40991/2):_

`define DATA is part of pkg but when it is imported outside module, my test is passing. How is that possible?

```verilog

package pkg_with_defines;
 
`define DATA
 
endpackage

```

inside tb\_top.sv

```verilog

import pkg_with_defines::*;
module tb_top;
 
´ifdef DATA
 logic bit data;
 endif
...
endmodule

```

---

_[View the full topic](https://verificationacademy.com/forums/t/module-cannot-see-defines-defined-in-pkg-if-this-pkg-is-imported-inside-module-what-is-the-reason-for-it/40991)._
