Merge pull request #340 from andrewcorrigan/master

suppresses all warnings reported by latest Xcode/AppleClang
This commit is contained in:
Mikko Mononen 2016-11-06 08:00:39 +02:00 committed by GitHub
commit cacb00b852

View File

@ -263,6 +263,11 @@ static NVGcompositeOperationState nvg__compositeOperationState(int op)
sfactor = NVG_ONE_MINUS_DST_ALPHA;
dfactor = NVG_ONE_MINUS_SRC_ALPHA;
}
else
{
sfactor = NVG_ONE;
dfactor = NVG_ZERO;
}
NVGcompositeOperationState state;
state.srcRGB = sfactor;
@ -461,7 +466,7 @@ NVGcolor nvgLerpRGBA(NVGcolor c0, NVGcolor c1, float u)
{
int i;
float oneminu;
NVGcolor cint = {0};
NVGcolor cint = {{{0}}};
u = nvg__clampf(u, 0.0f, 1.0f);
oneminu = 1.0f - u;
@ -2617,12 +2622,12 @@ int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, floa
type = NVG_NEWLINE;
break;
default:
if (iter.codepoint >= 0x4E00 && iter.codepoint <= 0x9FFF ||
iter.codepoint >= 0x3000 && iter.codepoint <= 0x30FF ||
iter.codepoint >= 0xFF00 && iter.codepoint <= 0xFFEF ||
iter.codepoint >= 0x1100 && iter.codepoint <= 0x11FF ||
iter.codepoint >= 0x3130 && iter.codepoint <= 0x318F ||
iter.codepoint >= 0xAC00 && iter.codepoint <= 0xD7AF)
if ((iter.codepoint >= 0x4E00 && iter.codepoint <= 0x9FFF) ||
(iter.codepoint >= 0x3000 && iter.codepoint <= 0x30FF) ||
(iter.codepoint >= 0xFF00 && iter.codepoint <= 0xFFEF) ||
(iter.codepoint >= 0x1100 && iter.codepoint <= 0x11FF) ||
(iter.codepoint >= 0x3130 && iter.codepoint <= 0x318F) ||
(iter.codepoint >= 0xAC00 && iter.codepoint <= 0xD7AF))
type = NVG_CJK_CHAR;
else
type = NVG_CHAR;