<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Thanks John.  The patch makes it very clear.<div><br></div><div>The problem is that we don't want to add static data to CIndex, as we want the functions to be as reentrant as possible.<div><br></div><div>Steve/Doug: I believe you guys discussed this one.  Comments?</div><div><br><div><div>On Oct 27, 2009, at 2:51 PM, John Thompson wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div class="gmail_quote">
<div>Thanks, Ted.</div>
<div> </div>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">I'm sorry I've been disconnected from this.  What particular code were you looking at that returned a 'const char*' that referred to the buffer associated with a temporary std::string?<br>
</blockquote></div>
<div>It's in clang_getTranslationUnitSpelling, clang_getDeclSpelling, and clang_getCursorSpelling.  The enclosed patch with my hacky work-around will show the specific places.</div>
<div><br>I also moved getLocationFromCursor to fix a VC++ message about the return type not being permitted inside an extern "C" {} block.<br clear="all"></div>
<div>-John</div>
<div><br>-- <br>John Thompson<br><a href="mailto:John.Thompson.JTSoftware@gmail.com">John.Thompson.JTSoftware@gmail.com</a><br><br></div>
<span><cindex_strings.patch></span>_______________________________________________<br>cfe-dev mailing list<br><a href="mailto:cfe-dev@cs.uiuc.edu">cfe-dev@cs.uiuc.edu</a><br>http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev<br></blockquote></div><br></div></div></body></html>