passlab / ompparser

ompparser: A Standalone and Unified OpenMP Parser
https://github.com/passlab/ompparser
Other
5 stars 1 forks source link

Test cases for incorrect use of directive, clauses and parameters #42

Open yanyh15 opened 5 years ago

yanyh15 commented 5 years ago

We need some failed test to verify the error report functions and robustness of the parser. So far the tests are in the following format:

#pragma omp atomic release hint(abc) read acq_rel
PASS: #pragma omp atomic acq_rel release read hint (abc)

How about something like this?

#pragma omp atomic release hint(abc) read acq_rel write
PASS: some meaningful and valid error msg
yanyh15 commented 5 years ago

Lots of test cases for incorrect use of directive/clauses are added. This is work-in-progress.

For incorrect or failed parsing, ompparser returns a NULL pointer indicating an unsuccessful parsing, and ompparser reports the error as much as it can right now to the terminal.