Giter VIP home page Giter VIP logo

cpp-pthread's Issues

Pre-release v1.3.2 is not running on Mac OS X

iMac-de-herbert:tests herbert$ ./without-cpp11-pthread-tests 5
lib version: cpp-pthread v1.3.1 - bc377cb2421f92243f452c150d5171270020a182 - compiled on Darwin Darwin Kernel Version 15.5.0: Tue Apr 19 18:36:36 PDT 2016; root:xnu-3248.50.21~8/RELEASE_X86_64.
add new work to thread group
add new work to thread group
add new work to thread group
add new work to thread group
add new work to thread group
Segmentation fault: 11

Fix performance related issue

include/pthread/exceptions.hpp:39,performance,passedByValue:
Function parameter 'message' should be passed by reference.

include/pthread/exceptions.hpp:71,performance,passedByValue:
Function parameter 'message' should be passed by reference.

include/pthread/mutex.hpp:83,performance,passedByValue:
Function parameter 'message' should be passed by reference.

include/pthread/exceptions.hpp:71,performance,passedByValue:
Function parameter 'message' should be passed by reference.

Doesn't compile on Fedora 23/gcc 5.3.1

Funny how compilers behave differently !!??

$ make
g++  -x c++ -std=c++11 -frtti    -I ../include -I ./ -c exceptions.cpp
exceptions.cpp:29:56: erreur : virt-specifiers in ‘what’ not allowed outside a class definition
   const char *pthread_exception::what() const noexcept override{
                                                        ^
Makefile:65: recipe for target 'exceptions.o' failed
make: *** [exceptions.o] Error 1

Use auto_ptr when compiling with pre C++11 compilers

This should avoid this message:

thread.cpp:126:12: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
       std::auto_ptr<pthread::abstract_thread> pat(_threads.front());
            ^
In file included from /usr/include/c++/5.3.1/memory:81:0,
                 from ../include/pthread/thread.hpp:15,
                 from thread.cpp:9:
/usr/include/c++/5.3.1/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;

thread.cpp:75:23: erreur : ‘PTHREAD_STACK_MIN’ was not declared in this scope

g++ -I ../include -I ./ -x c++ -std=c++11 -frtti -g -O2 -c thread.cpp
thread.cpp: Dans le constructeur ‘pthread::thread::thread(const pthread::runnable&, std::size_t)’:
thread.cpp:75:23: erreur : ‘PTHREAD_STACK_MIN’ was not declared in this scope
if ( stack_size > PTHREAD_STACK_MIN && (rc = pthread_attr_setstacksize(&attr, stack_size)) != 0 ){
^
Makefile:64: recipe for target 'thread.o' failed

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.