vector.com|Contact
Search tips

apple banana
Find rows that contain at least one of the two words.

+apple +juice
Find rows that contain both words.

+apple macintosh
Find rows that contain the word 'apple', but rank rows higher if they also contain 'macintosh'.

+apple -macintosh
Find rows that contain the word 'apple' but not 'macintosh'.

+apple ~macintosh
Find rows that contain the word 'apple', but if the row also contains the word 'macintosh', rate it lower than if row does not. This is "softer" than a search for '+apple -macintosh', for which the presence of 'macintosh' causes the row not to be returned at all.

+apple +(>turnover >strudel)
Find rows that contain the words 'apple' and 'turnover', or 'apple' and 'strudel' (in any order), but rank 'apple turnover' higher than 'apple strudel'.

apple*
Find rows that contain words such as 'apple', 'apples', 'applesauce', or 'applet'.

"some words"
Find rows that contain the exact phrase 'some words' (for example, rows that contain 'some words of wisdom' but not "some noise words").

By continuing to use this site you agree to the use of cookies. For more information and to find out how to change this click here. Accept Cookies
Please enable cookies in your browser for this website.
Search:
Advanced search

Post Instrumentation Script to #undef a Recursive Macro

Last updated: 2019-11-04
Issue:

Including a header file that uses the struct sigaction results in the following compilation error:

error: union sigaction::<anonymous> has no member names __sigaction_handler
 

Solution:

The problem is a recursive macro in signal.h:

# define sa_handler __sigaction_handler.sa_handler
 

When setting the expanded header to collapse system headers or collapse non-search directory headers, the effect is that the header file is expanded twice and the harness code as a result then references sigaction_handler.
 

In the VectorCAST unit test, the right place to fix this error is by adding a #undef in driver prefix user code. In the VectorCAST QA, however, it will require that a post-instrument script is used to insert the #undef in the instrumented source file. Here is an example script:
 

sed -i -e '/#include .*signal.h"/s/$/\
#undef sa_handler/' $1

 

 
Article Options
2019-11-04
Views: 7