# LRM Example of polymorphism wrong?

**URL:** <https://verificationacademy.com/forums/t/lrm-example-of-polymorphism-wrong/31965>\
**Category:** SystemVerilog\
**Tags:** Polymorhphism, SystemVerilog\
**Created:** [June 20, 2016, 9:13am UTC](https://verificationacademy.com/forums/t/lrm-example-of-polymorphism-wrong/31965 "2016-06-20T09:13:12Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![rohitk](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/r/a698b9/32.png) [@rohitk](https://verificationacademy.com/forums/u/rohitk)\
**Post date:** [June 20, 2016, 10:27am UTC](https://verificationacademy.com/forums/t/lrm-example-of-polymorphism-wrong/31965/2 "2016-06-20T10:27:49Z")

</div>

_In reply to [prasadaddagarla](https://verificationacademy.com/forums/t/lrm-example-of-polymorphism-wrong/31965):_

There is no section in lrm which says re-defining is illegal in class inheritance. Whenever a child class extends base class it gets all it’s contents which includes variables, methods, constraints; now in child class one can re-declare any of these and that would get effective for child class.

Thanks

---

_[View the full topic](https://verificationacademy.com/forums/t/lrm-example-of-polymorphism-wrong/31965)._
