From 517513645afb8eaf4841e7b7035f1ba3a9c7cd57 Mon Sep 17 00:00:00 2001 From: Tim Foley Date: Thu, 15 Jun 2017 13:12:51 -0700 Subject: Rename `Slang::Compiler` -> `Slang` This gets rid of one unecessary namespace. --- source/slang/compiled-program.h | 101 +++++++++++----------------------------- 1 file changed, 27 insertions(+), 74 deletions(-) (limited to 'source/slang/compiled-program.h') diff --git a/source/slang/compiled-program.h b/source/slang/compiled-program.h index 7a86dfe90..1766127b2 100644 --- a/source/slang/compiled-program.h +++ b/source/slang/compiled-program.h @@ -8,89 +8,42 @@ namespace Slang { - namespace Compiler + void IndentString(StringBuilder & sb, String src); + + struct EntryPointResult { -#if 0 - class ShaderMetaData - { - public: - CoreLib::String ShaderName; - CoreLib::EnumerableDictionary> ParameterSets; // bindingName->DescSet - }; + String outputSource; + }; - class StageSource - { - public: - String MainCode; - List BinaryCode; - }; + struct TranslationUnitResult + { + String outputSource; + List entryPoints; + }; - class CompiledShaderSource - { - public: - EnumerableDictionary Stages; - ShaderMetaData MetaData; - }; -#endif + class CompileResult + { + public: + DiagnosticSink* mSink = nullptr; - void IndentString(StringBuilder & sb, String src); + // Per-translation-unit results + List translationUnits; - struct EntryPointResult + CompileResult() + {} + ~CompileResult() { - String outputSource; - }; - - struct TranslationUnitResult + } + DiagnosticSink * GetErrorWriter() { - String outputSource; - List entryPoints; - }; - - class CompileResult + return mSink; + } + int GetErrorCount() { - public: - DiagnosticSink* mSink = nullptr; - -#if 0 - String ScheduleFile; - RefPtr Program; - EnumerableDictionary CompiledSource; // shader -> stage -> code -#endif - - // Per-translation-unit results - List translationUnits; - -#if 0 - void PrintDiagnostics() - { - for (int i = 0; i < sink.diagnostics.Count(); i++) - { - fprintf(stderr, "%S(%d): %s %d: %S\n", - sink.diagnostics[i].Position.FileName.ToWString(), - sink.diagnostics[i].Position.Line, - getSeverityName(sink.diagnostics[i].severity), - sink.diagnostics[i].ErrorID, - sink.diagnostics[i].Message.ToWString()); - } - } -#endif - - CompileResult() - {} - ~CompileResult() - { - } - DiagnosticSink * GetErrorWriter() - { - return mSink; - } - int GetErrorCount() - { - return mSink->GetErrorCount(); - } - }; + return mSink->GetErrorCount(); + } + }; - } } #endif \ No newline at end of file -- cgit v1.2.3