google / google/xls

An `assert_fail` construct

Open
#481 0 comments 0 reactions 0 assignees View on GitHub
dslx enhancement
Dominant language
C++
Stars
1.9k
Forks
283
Avg merge
2d 10h
Merged PRs (30d)
135

Description

It would be nice if there an `assert_fail` construct, or similar. I imagine it would only be useful in tests, just like today's `assert`. Use case:

I want to create a unit test of a function, where I expect my input will cause the function to `fail!` That is, I want to test that my function fails when it should fail.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.