diff options
author | Ethan Nicholas <ethannicholas@google.com> | 2018-06-12 11:05:59 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-06-12 19:16:03 +0000 |
commit | d9d33c33dee064da260301faa313703e465d44c5 (patch) | |
tree | f2e9a592acde1715d71381d8ff7c97fdaf58edac /src/sksl/SkSLHCodeGenerator.cpp | |
parent | 22be4c4801f957f2820b9001b02b892f4b87a157 (diff) |
renamed SkSL's assert macros
Since SkSL needs to run outside of Skia, it was originally using its
own ASSERT macro, which mapped to SkASSERT when inside of Skia. This is
causing conflicts with one or two other ASSERT macros defined around
Skia, so to avoid that I am switching SkSL over to just use Skia's
standard naming for these macros.
Bug: skia:
Change-Id: I115435d7282da03d076c6080f7b13d1972b9eb9f
Reviewed-on: https://skia-review.googlesource.com/134322
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Diffstat (limited to 'src/sksl/SkSLHCodeGenerator.cpp')
-rw-r--r-- | src/sksl/SkSLHCodeGenerator.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/sksl/SkSLHCodeGenerator.cpp b/src/sksl/SkSLHCodeGenerator.cpp index 2c406aad8d..d6a92d3bac 100644 --- a/src/sksl/SkSLHCodeGenerator.cpp +++ b/src/sksl/SkSLHCodeGenerator.cpp @@ -54,7 +54,7 @@ String HCodeGenerator::FieldType(const Context& context, const Type& type, } else if (type == *context.fFragmentProcessor_Type) { // we don't store fragment processors in fields, they get registered via // registerChildProcessor instead - ASSERT(false); + SkASSERT(false); return "<error>"; } return ParameterType(context, type, layout); @@ -111,13 +111,13 @@ void HCodeGenerator::writeExtraConstructorParams(const char* separator) { lastIdentifierLength = 0; foundBreak = false; } - ASSERT(lastIdentifierLength < BUFFER_SIZE); + SkASSERT(lastIdentifierLength < BUFFER_SIZE); lastIdentifier[lastIdentifierLength] = c; ++lastIdentifierLength; } else { foundBreak = true; if (c == ',') { - ASSERT(lastIdentifierLength < BUFFER_SIZE); + SkASSERT(lastIdentifierLength < BUFFER_SIZE); lastIdentifier[lastIdentifierLength] = 0; this->writef("%s%s", separator, lastIdentifier); separator = ", "; @@ -127,7 +127,7 @@ void HCodeGenerator::writeExtraConstructorParams(const char* separator) { } } if (lastIdentifierLength) { - ASSERT(lastIdentifierLength < BUFFER_SIZE); + SkASSERT(lastIdentifierLength < BUFFER_SIZE); lastIdentifier[lastIdentifierLength] = 0; this->writef("%s%s", separator, lastIdentifier); } |