# How to make error flags of \*E and \*W become UVM\_ERROR and UVM\_WARNING?

**URL:** <https://verificationacademy.com/forums/t/how-to-make-error-flags-of-e-and-w-become-uvm-error-and-uvm-warning/31813>\
**Category:** UVM\
**Tags:** UVM, assert, randomization-error, error-flags\
**Created:** [May 12, 2016, 10:38am UTC](https://verificationacademy.com/forums/t/how-to-make-error-flags-of-e-and-w-become-uvm-error-and-uvm-warning/31813 "2016-05-12T10:38:32Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![dave\_59](https://verificationacademy.com/forums/user_avatar/verificationacademy.com/dave_59/32/4499_2.png) [@dave\_59](https://verificationacademy.com/forums/u/dave_59)\
**Post date:** [May 12, 2016, 1:47pm UTC](https://verificationacademy.com/forums/t/how-to-make-error-flags-of-e-and-w-become-uvm-error-and-uvm-warning/31813/3 "2016-05-12T13:47:45Z")

</div>

_In reply to [chr\_sue](https://verificationacademy.com/forums/t/how-to-make-error-flags-of-e-and-w-become-uvm-error-and-uvm-warning/31813/2):_  
\*E and \*W are tool specific generated error and warning messages. Catching tool generated messages is going to be tool specific.

The problem here is the test writer was lazy and did not check the return status of a call to randomize. (Don’t ignore those warnings when you call a function with a return value as a statement instead of using it an expression). Same for $cast and using the action block of an assertion.

---

_[View the full topic](https://verificationacademy.com/forums/t/how-to-make-error-flags-of-e-and-w-become-uvm-error-and-uvm-warning/31813)._
