From de6ca4df6668aa4f3f5113410e2e898e37cd7bc4 Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Tue, 6 Nov 2018 19:17:10 -0500 Subject: Made sameStageSpecifiedMoreThanOnce a warning instead of an error. (#714) --- source/slang/diagnostic-defs.h | 2 +- .../command-line/entry-point-redundant-stage.slang.1.expected | 5 +++-- .../command-line/entry-point-redundant-stage.slang.expected | 5 +++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/source/slang/diagnostic-defs.h b/source/slang/diagnostic-defs.h index f28666522..8466485e7 100644 --- a/source/slang/diagnostic-defs.h +++ b/source/slang/diagnostic-defs.h @@ -75,7 +75,7 @@ DIAGNOSTIC( 21, Error, expectedArgumentForOption, "expected an argument for c DIAGNOSTIC( 24, Error, unknownLineDirectiveMode, "unknown '#line' directive mode '$0'"); DIAGNOSTIC( 25, Error, unknownFloatingPointMode, "unknown floating-point mode '$0'"); -DIAGNOSTIC( 30, Error, sameStageSpecifiedMoreThanOnce, "the stage '$0' was specified more than once for entry point '$1'") +DIAGNOSTIC( 30, Warning, sameStageSpecifiedMoreThanOnce, "the stage '$0' was specified more than once for entry point '$1'") DIAGNOSTIC( 31, Error, conflictingStagesForEntryPoint, "conflicting stages have been specified for entry point '$0'") DIAGNOSTIC( 32, Warning, explicitStageDoesntMatchImpliedStage, "the stage specified for entry point '$0' ('$1') does not match the stage implied by the source file name ('$2')") DIAGNOSTIC( 33, Error, stageSpecificationIgnoredBecauseNoEntryPoints, "one or more stages were specified, but no entry points were specified with '-entry'") diff --git a/tests/diagnostics/command-line/entry-point-redundant-stage.slang.1.expected b/tests/diagnostics/command-line/entry-point-redundant-stage.slang.1.expected index 36674b409..83eba2fb4 100644 --- a/tests/diagnostics/command-line/entry-point-redundant-stage.slang.1.expected +++ b/tests/diagnostics/command-line/entry-point-redundant-stage.slang.1.expected @@ -1,6 +1,7 @@ -result code = 1 +result code = -1 standard error = { -(0): error 30: the stage 'vertex' was specified more than once for entry point 'vsMain' +(0): warning 30: the stage 'vertex' was specified more than once for entry point 'vsMain' +tests/diagnostics/command-line/entry-point-redundant-stage.slang(6): error 38000: no function found matching entry point name 'vsMain' } standard output = { } diff --git a/tests/diagnostics/command-line/entry-point-redundant-stage.slang.expected b/tests/diagnostics/command-line/entry-point-redundant-stage.slang.expected index e5a66e0fd..a69cae93e 100644 --- a/tests/diagnostics/command-line/entry-point-redundant-stage.slang.expected +++ b/tests/diagnostics/command-line/entry-point-redundant-stage.slang.expected @@ -1,6 +1,7 @@ -result code = 1 +result code = -1 standard error = { -(0): error 30: the stage 'vertex' was specified more than once for entry point 'main' +(0): warning 30: the stage 'vertex' was specified more than once for entry point 'main' +tests/diagnostics/command-line/entry-point-redundant-stage.slang(6): error 38000: no function found matching entry point name 'main' } standard output = { } -- cgit v1.2.3