-
assigned issue to
Spurious error on omp parallel for`
Issue #48
resolved
When vera++ encounters an OpenMP-style for, it mistakenly thinks a standard C for loop is about to follow. But it's just a pragma.
Source:
$ cat parhello.c
// Copyright (c) YelloSoft
#include <omp.h>
#include <stdio.h>
#include <string.h>
int main() {
char* s = "Hello World!\n";
size_t i;
#pragma omp parallel for
for (i = 0; i < strlen(s); i++) {
(void) putc(s[i], stdout);
}
return 0;
}
Trace:
$ vera++ parhello.c
parhello.c:12: keyword 'for' not followed by a single space
Comments (3)
-
-
- changed status to resolved
don't force space after omp parallel for - fix
#48→ <<cset ef34ffd8cfcc>>
-
Issue
#53was marked as a duplicate of this issue. - Log in to comment