Subject:
|
Declarations in header files
|
Newsgroups:
|
lugnet.robotics.rcx.legos
|
Date:
|
Tue, 27 Mar 2001 11:55:18 GMT
|
Viewed:
|
1331 times
|
| |
| |
Hi!
This is very technical, but:
does the declaration of an
"extern inline const void" function really make sense? GCC accepts it, but
that is a VERY lenient compiler.
An extern function should be definition not have a definition, and 'const void'
gives a warning since const is not really applicable to void -- it lacks any
meaning.
I have found this idiom in many of the header files.
I also find it in slightly bad taste to have assembler in inline assembly
instead of as separate files. This makes it a bit harder to port the code to a
new compiler :(
/jakob
|
|
Message has 1 Reply: | | Re: Declarations in header files
|
| (...) "extern inline" means that we are defining an inline function, but if the inline function is not used, there is also an externally defined function with the same purpose. So, if you compile without optimization, it acts like "extern void (...) (24 years ago, 18-Apr-01, to lugnet.robotics.rcx.legos)
|
2 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|