On Tue, Oct 17, 2017 at 11:59 AM, Peter Dimov via Boost < boost@lists.boost.org> wrote:
Robert Ramey wrote:
personally I don't see any difference between #warning and the already existing and portable #pragma message - which is what I use on a regular basis.
`#pragma message("foo")` results in the following output:
foo
and shows nothing in the IDE warning list. So you either don't see it, or if you do, you have no clue where did it come from.
`#warning foo` would result in the following output:
source_file(source_line): warning C7563: #warning foo
which would then be shown as a warning in the IDE.
Yes, that's what make #warning more attractive.
There is a hack on Stackoverflow https://stackoverflow.com/questions/5966594 to use a macro cascade to solve the problem. --Beman