# Assigning a bit in SV Assertion

**URL:** <https://verificationacademy.com/forums/t/assigning-a-bit-in-sv-assertion/36810>\
**Category:** SystemVerilog\
**Tags:** Assertion-Based-Verification, assert-property, SystemVerilog, assertion\
**Created:** [November 16, 2019, 8:23am UTC](https://verificationacademy.com/forums/t/assigning-a-bit-in-sv-assertion/36810 "2019-11-16T08:23:54Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![atanu.biswas](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/a/9de0a6/32.png) [@atanu.biswas](https://verificationacademy.com/forums/u/atanu.biswas)\
**Post date:** [November 16, 2019, 5:39pm UTC](https://verificationacademy.com/forums/t/assigning-a-bit-in-sv-assertion/36810/3 "2019-11-16T17:39:49Z")

</div>

_In reply to [dave\_59](https://verificationacademy.com/forums/t/assigning-a-bit-in-sv-assertion/36810/2):_

Hi Dave,

The match\_found bit should be set whenever a first match occurs depending upon the comparison statement in the consequent expression. The bit should be reset again when a write\_cycle is detected. This is the behaviour that I want. The match\_found bit is used to check that the comparison statement that was used inside the first\_match() remains valid as long as next write\_cycle is detected. That bit is used in an always\_comb procedural block.

---

_[View the full topic](https://verificationacademy.com/forums/t/assigning-a-bit-in-sv-assertion/36810)._
