| 831 | } |
| 832 | |
| 833 | bool cmMakefile::ReadListFileAsString(std::string const& content, |
| 834 | std::string const& virtualFileName) |
| 835 | { |
| 836 | std::string filenametoread = cmSystemTools::CollapseFullPath( |
| 837 | virtualFileName, this->GetCurrentSourceDirectory()); |
| 838 | |
| 839 | ListFileScope scope(this, filenametoread); |
| 840 | |
| 841 | cmListFile listFile; |
| 842 | if (!listFile.ParseString(content, virtualFileName.c_str(), |
| 843 | this->GetMessenger(), this->Backtrace)) { |
| 844 | return false; |
| 845 | } |
| 846 | |
| 847 | #ifdef CMake_ENABLE_DEBUGGER |
| 848 | if (this->GetCMakeInstance()->GetDebugAdapter()) { |
| 849 | this->GetCMakeInstance()->GetDebugAdapter()->OnFileParsedSuccessfully( |
| 850 | filenametoread, listFile.Functions); |
| 851 | } |
| 852 | #endif |
| 853 | |
| 854 | this->RunListFile(listFile, filenametoread); |
| 855 | if (cmSystemTools::GetFatalErrorOccurred()) { |
| 856 | scope.Quiet(); |
| 857 | } |
| 858 | return true; |
| 859 | } |
| 860 | |
| 861 | void cmMakefile::RunListFile(cmListFile const& listFile, |
| 862 | std::string const& filenametoread, |
no test coverage detected