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

Method QueueFile

BeefBoot/BootApp.cpp:405–430  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

403}
404
405void BootApp::QueueFile(const StringImpl& path, void* project)
406{
407 String ext;
408 ext = GetFileExtension(path);
409 if ((ext.Equals(".bf", StringImpl::CompareKind_OrdinalIgnoreCase)) ||
410 (ext.Equals(".cs", StringImpl::CompareKind_OrdinalIgnoreCase)))
411 {
412 int len;
413 const char* data = LoadTextData(path, &len);
414 if (data == NULL)
415 {
416 Fail(StrFormat("Unable to load file '%s'", path.c_str()));
417 return;
418 }
419
420 bool worked = true;
421 void* bfParser = BfSystem_CreateParser(mSystem, project);
422 BfParser_SetSource(bfParser, data, len, path.c_str());
423 //bfParser.SetCharIdData(charIdData);
424 worked &= BfParser_Parse(bfParser, mPassInstance, false);
425 worked &= BfParser_Reduce(bfParser, mPassInstance);
426 worked &= BfParser_BuildDefs(bfParser, mPassInstance, NULL, false);
427
428 delete data;
429 }
430}
431
432void BootApp::QueuePath(const StringImpl& path)
433{

Callers

nothing calls this directly

Calls 7

FailFunction · 0.85
BfParser_SetSourceFunction · 0.85
BfParser_ParseFunction · 0.85
BfParser_ReduceFunction · 0.85
BfParser_BuildDefsFunction · 0.85
EqualsMethod · 0.45
c_strMethod · 0.45

Tested by

no test coverage detected