Error Too Many Arguments Provided To Function-like Macro Invocation
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more too many arguments provided to function-like macro invocation xcode about Stack Overflow the company Business Learn more about hiring developers or posting ads too many arguments in macro invocation with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Too many arguments provided to function-like macro invocation [duplicate] up vote 7 down vote favorite 1 This question already has an answer here: Getting too many arguments provided to function-like macro invocation compile error while defining lambda inside assert (assert.h) in Xcode [c++] 2 answers Say we have an implementation of std::aligned_storage. I've defined two macros for the alignof and alignas operators. #include
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question Page Not Found This question was voluntarily removed by its author. Here are some similar questions that might be relevant: error while compiling Zxing iphone : too few arguments compile error with function-like macro xcode http://stackoverflow.com/questions/38030048/too-many-arguments-provided-to-function-like-macro-invocation function-like macro syntax Chained macro invocations. Argument in parentheses treated differently? XCode 5 GM linker error: too many compact unwind infos in function anon for architecture i386 Too many arguments to function call, expected 0, have 3 Bizarre Swift Compiler Error: “Expression too complex” on a string concatenation Creating a function in compile time using a bitmap like macro Getting too many arguments provided to http://stackoverflow.com/questions/39910252/too-many-arguments-provided-to-function-like-macro-invocation-compile-error function-like macro invocation compile error while defining lambda inside assert (assert.h) in Xcode [c++] Too many arguments provided to function-like macro invocation Try a Google Search Try searching for similar questions Browse our recent questions Browse our popular tags If you feel something is missing that should be here, contact us. about us tour help blog chat data legal privacy policy work here advertising info mobile contact us feedback Technology Life / Arts Culture / Recreation Science Other Stack Overflow Server Fault Super User Web Applications Ask Ubuntu Webmasters Game Development TeX - LaTeX Programmers Unix & Linux Ask Different (Apple) WordPress Development Geographic Information Systems Electrical Engineering Android Enthusiasts Information Security Database Administrators Drupal Answers SharePoint User Experience Mathematica Salesforce ExpressionEngine® Answers Cryptography Code Review Magento Signal Processing Raspberry Pi Programming Puzzles & Code Golf more (7) Photography Science Fiction & Fantasy Graphic Design Movies & TV Music: Practice & Theory Seasoned Advice (cooking) Home Improvement Personal Finance & Money Academia more (8) English Language & Usage Skeptics Mi Yodeya (Judaism) Travel Christianity English Language Learners Japanese Language Arqade (gaming) Bicycles Role-playing Games Anime & Manga more (18) Mathematics Cross Validated (stats
Sign in Pricing Blog Support Search GitHub This repository Watch 25 Star 408 Fork 163 flori/json Code Issues 60 Pull requests 15 Projects https://github.com/flori/json/issues/229 0 Wiki Pulse Graphs New issue Incompatibility with Ruby 2.2.0 #229 Closed dougo opened this Issue Dec 25, 2014 · 36 comments Projects None yet Labels None yet https://sourceforge.net/p/cscope/bugs/289/ Milestone No milestone Assignees No one assigned 30 participants and others dougo commented Dec 25, 2014 I upgraded to Ruby 2.2.0, but now I get errors when I too many install the JSON gem: bash-3.2$ gem install json Fetching: json-1.8.1.gem (100%) Building native extensions. This could take a while... ERROR: Error installing json: ERROR: Failed to build gem native extension. /Users/dorleans/.rbenv/versions/2.2.0/bin/ruby -r ./siteconf20141225-66244-1qaxb2p.rb extconf.rb creating Makefile make "DESTDIR=" clean make "DESTDIR=" compiling generator.c In file included from generator.c:1: ./../fbuffer/fbuffer.h:175:47: error: too few arguments provided to function-like macro invocation VALUE result too many arguments = rb_str_new(FBUFFER_PAIR(fb)); ^ /Users/dorleans/.rbenv/versions/2.2.0/include/ruby-2.2.0/ruby/intern.h:793:9: note: macro 'rb_str_new' defined here #define rb_str_new(str, len) __extension__ ( \ ^ In file included from generator.c:1: ./../fbuffer/fbuffer.h:175:11: warning: incompatible pointer to integer conversion initializing 'VALUE' (aka 'unsigned long') with an expression of type 'VALUE (const char *, long)' [-Wint-conversion] VALUE result = rb_str_new(FBUFFER_PAIR(fb)); ^ ~~~~~~~~~~ 1 warning and 1 error generated. make: *** [generator.o] Error 1 make failed, exit code 2 Gem files will remain installed in /Users/dorleans/.rbenv/versions/2.2.0/lib/ruby/gems/2.2.0/gems/json-1.8.1 for inspection. Results logged to /Users/dorleans/.rbenv/versions/2.2.0/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-13/2.2.0-static/json-1.8.1/gem_make.out bash-3.2$ ruby --version ruby 2.2.0p0 (2014-12-25 revision 49005) [x86_64-darwin13] bash-3.2$ gem --version 2.4.5 I don't see anything about rb_str_new in the Ruby 2.2.0 change log, so maybe I just have something wrong with my environment? Any tips would be appreciated. 👍 3 😄 2 kgrz commented Dec 26, 2014 Not an expert in C and can't figure out why the macro expansion is not working properly. I was able to push a small fix by avoiding the use of FBUFFER_PAIR and using FBUFFER_PTR and FBUFFER_LEN as arguments to the rb_str_new function and get the extension t
by: broeker, jcduell, nhorman Summary Files Reviews Support Wiki Mailing Lists Tickets ▾ Bugs Feature Requests Support Requests Patches News Code Create Ticket View Stats Group Searches Changes Closed Tickets Open Tickets Help Formatting Help #289 Bugs Milestone: None Status: open Owner: nobody Labels: build failed (1) Priority: 5 Updated: 2015-01-31 Created: 2015-01-20 Creator: Randy Private: No While building gives build errors on release 15.8a ./configure make ~~~~~ In file included from build.c:52: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/curses.h:539:36: error: too many arguments provided to function-like macro invocation extern NCURSES_EXPORT(int) cbreak (void); ... ^ ./constants.h:125:11: note: macro 'cbreak' defined here define cbreak() crmode() / name change / ^ ~~~~~~ Discussion Hans-Bernhard Broeker - 2015-01-20 labels: Build failed --> build failed Description has changed: Diff: --- old +++ new @@ -2,7 +2,7 @@ ./configure make - +~~~~~ In file included from build.c:52: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/curses.h:539:36: error: too many arguments provided to function-like macro invocation @@ -11,22 +11,4 @@ ./constants.h:125:11: note: macro 'cbreak' defined here # define cbreak() crmode() /* name change */ ^ -In file included from build.c:52: -/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/curses.h:564:40: error: - too many arguments provided to function-like macro invocation -extern NCURSES_EXPORT(char) erasechar (void); ... - ^ -./constants.h:132:11: note: macro 'erasechar' defined here -# define erasechar() (_tty.sg_erase) /* equivalent */ - ^ -In file included from build.c:52: -/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/curses.h:600:39: error: - too many arguments provided to function-like macro invocation -extern NCURSES_EXPORT(char) killchar (void); ... - ^ -./constants.h:133:11: note: macro 'killchar' define