another cout?

28 views
Skip to first unread message

Ben Goodrich

unread,
Jun 14, 2016, 3:24:09 PM6/14/16
to stan development mailing list
For the RStan check with the 2.10 branch, I get

* checking compiled code ... NOTE
File rstan/libs/rstan.so’:
 
Found _ZSt4cout’, possibly from std::cout (C++)
   
Object: lang__ast_def.o

Compiled code should not call entry points which might terminate R nor
write to stdout
/stderr instead of to the console, nor the system RNG.

but I don't know where it is coming from. I don't see any useage of cout except in tests.

Bob Carpenter

unread,
Jun 14, 2016, 3:49:20 PM6/14/16
to stan...@googlegroups.com
Good catch. I created a pull request to fix it:

https://github.com/stan-dev/stan/pull/1921

Is there a way we can catch these easily in pull requests?
I just did

> grep -R cout src/stan

I probably inserted this one as I'm the one usually working
on the AST.

- Bob
> --
> You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+u...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Ben Goodrich

unread,
Jun 14, 2016, 6:52:31 PM6/14/16
to stan development mailing list
On Tuesday, June 14, 2016 at 3:49:20 PM UTC-4, Bob Carpenter wrote:
Is there a way we can catch these easily in pull requests?

For cout and cerr, this has happened enough times that we could probably have a git pull hook that greps for them. In general, we would have to build rstan against develop and run R CMD check, but most of the time Travis builds against master.

Ben


Reply all
Reply to author
Forward
0 new messages