MCPcopy Create free account
hub / github.com/beefytech/Beef / ToString

Method ToString

IDEHelper/DbgModule.cpp:389–569  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

387};
388
389NS_BF_DBG_END
390
391//////////////////////////////////////////////////////////////////////////
392
393void DbgSubprogram::ToString(StringImpl& str, bool internalName)
394{
395 if ((mInlineeInfo != NULL) && (mInlineeInfo->mInlineeId != 0))
396 mCompileUnit->mDbgModule->FixupInlinee(this);
397
398 PopulateSubprogram();
399
400 if (mCheckedKind == BfCheckedKind_Checked)
401 str += "[Checked] ";
402 else if (mCheckedKind == BfCheckedKind_Unchecked)
403 str += "[Unchecked] ";
404
405 auto language = GetLanguage();
406 if (mName == NULL)
407 {
408 if (mLinkName[0] == '<')
409 {
410 str += mLinkName;
411 return;
412 }
413 str = BfDemangler::Demangle(StringImpl::MakeRef(mLinkName), language);
414 // Strip off the params since we need to generate those ourselves
415 int parenPos = (int)str.IndexOf('(');
416 if (parenPos != -1)
417 str = str.Substring(0, parenPos);
418 }
419 else if ((mHasQualifiedName) && (!internalName))
420 {
421 const char* cPtr = mName;
422 if (strncmp(cPtr, "_bf::", 5) == 0)
423 {
424 cPtr += 5;
425 for ( ; true; cPtr++)
426 {
427 char c = *cPtr;
428 if (c == 0)
429 break;
430
431 if ((c == '_') && (cPtr[-1] == ':'))
432 {
433 if (strcmp(cPtr, "__BfCtor") == 0)
434 {
435 str += "this";
436 break;
437 }
438 if (strcmp(cPtr, "__BfStaticCtor") == 0)
439 {
440 str += "this$static";
441 break;
442 }
443 if (strcmp(cPtr, "__BfCtorClear") == 0)
444 {
445 str += "this$clear";
446 break;

Callers 15

CheckMethodMethod · 0.45
ResolveTypeRefMethod · 0.45
TypeToStringMethod · 0.45
CastMethod · 0.45
DoLookupFieldMethod · 0.45
CheckTupleCreationMethod · 0.45
AutocompleteCheckTypeMethod · 0.45
DoLookupIdentifierMethod · 0.45
VisitMethod · 0.45
LookupSplatMemberMethod · 0.45
LookupQualifiedNameMethod · 0.45

Calls 11

StringClass · 0.85
SubstringMethod · 0.80
AppendMethod · 0.80
IsBfObjectMethod · 0.80
ToStringFunction · 0.50
FixupInlineeMethod · 0.45
IndexOfMethod · 0.45
emptyMethod · 0.45
lengthMethod · 0.45
IsPointerMethod · 0.45
GetStrideMethod · 0.45

Tested by

no test coverage detected