BVB Source Codes

mars Show gen_maybe_include.pl Source code

Return Download mars: download gen_maybe_include.pl Source code - Download mars Source code - Type:.pl
  1. #!/usr/bin/perl -w
  2. #
  3. # Boost.Function library
  4. #
  5. # Copyright (C) 2001-2003 Douglas Gregor (gregod@cs.rpi.edu)
  6. #
  7. # Permission to copy, use, sell and distribute this software is granted
  8. # provided this copyright notice appears in all copies.
  9. # Permission to modify the code and to distribute modified code is granted
  10. # provided this copyright notice appears in all copies, and a notice
  11. # that the code was modified is included with the copyright notice.
  12. #
  13. # This software is provided "as is" without express or implied warranty,
  14. # and with no claim as to its suitability for any purpose.
  15. #
  16. # For more information, see http://www.boost.org
  17. use English;
  18.  
  19. $max_args = $ARGV[0];
  20.  
  21. open (OUT, ">maybe_include.hpp") or die("Cannot write to maybe_include.hpp");
  22. for($on_arg = 0; $on_arg <= $max_args; ++$on_arg) {
  23.     if ($on_arg == 0) {
  24.         print OUT "#if";
  25.     }
  26.     else {
  27.         print OUT "#elif";
  28.     }
  29.     print OUT " BOOST_FUNCTION_NUM_ARGS == $on_arg\n";
  30.     print OUT "#  ifndef BOOST_FUNCTION_$on_arg\n";
  31.     print OUT "#    define BOOST_FUNCTION_$on_arg\n";
  32.     print OUT "#    include <boost/function/function_template.hpp>\n";
  33.     print OUT "#  endif\n";
  34. }
  35. print OUT "#else\n";
  36. print OUT "#  error Cannot handle Boost.Function objects that accept more than $max_args arguments!\n";
  37. print OUT "#endif\n";
  38.  
downloadgen_maybe_include.pl Source code - Download mars Source code
Related Source Codes/Software:
Hero - Elegant transition library for iOS & tvOS 2017-06-09
deep-photo-styletransfer - Code and data for paper "Deep Photo Style Transfer... 2017-06-09
mastodon - A GNU Social-compatible microblogging server ... 2017-06-09
plyr - A simple HTML5, YouTube and Vimeo player ... 2017-06-08
prepack - Prepack is a partial evaluator for JavaScript. Pre... 2017-06-08
Public-APIs - 2017-06-09
lottie-ios - An iOS library to natively render After Effects ve... 2017-06-09
Awesome-Hacking - A collection of various awesome lists for hackers,... 2017-06-09
algorithms - Minimal examples of data structures and algorithms... 2017-06-10
lectures - Oxford Deep NLP 2017 course 2017-06-10
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top