<html>
<head>
<base href="http://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Problem with inline C functions in Apple LLVM in XCode 5"
href="http://llvm.org/bugs/show_bug.cgi?id=17572">17572</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Problem with inline C functions in Apple LLVM in XCode 5
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>MacOS X
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>-New Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>konevaanna2012@gmail.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Dear Sirs!
My name is Anna. I am from Moscow, Russia.
I have read these article and question about the inline C functions in C99:
<a href="http://www.drdobbs.com/the-new-c-inline-functions/184401540">http://www.drdobbs.com/the-new-c-inline-functions/184401540</a> and
<a href="http://stackoverflow.com/questions/3514413/objective-c-inline-function-symbol-not-found">http://stackoverflow.com/questions/3514413/objective-c-inline-function-symbol-not-found</a>.
So according to them I organized the program sources like that:
File Foo.h:
inline void foo()
{
printf("Hello, World\n");
}
File Foo.c:
extern inline void foo();
And the file main.m looks like this:
#import <Foundation/Foundation.h>
#include "Foo.h"
int main(int argc, const char * argv[])
{
foo();
// insert code here...
NSLog(@"Hello, World!");
return 0;
}
And before the last XCode 5.0 which contains the Apple LLVM 5.0 it was compiled
successfully. But with 5.0 version it fails and the linker produces the error
that a symbol "foo" is undefined.
So please tell me, how should I organize the source files now to make it
compile?
Best regards,
Anna.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>