summaryrefslogtreecommitdiffstats
path: root/vendor/modernc.org/cc/v3/check.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2022-11-27 00:42:16 +0100
committerGitHub <noreply@github.com>2022-11-27 00:42:16 +0100
commit4fd0a7672777f0ed15692ae2ba47838208537558 (patch)
treeb119834a8b9ee78aa8f1b2ad05efa7da50516cbf /vendor/modernc.org/cc/v3/check.go
parent6da9d567dc9195e9a5211f23a6795a41f56a1bfc (diff)
downloadmatterbridge-msglm-4fd0a7672777f0ed15692ae2ba47838208537558.tar.gz
matterbridge-msglm-4fd0a7672777f0ed15692ae2ba47838208537558.tar.bz2
matterbridge-msglm-4fd0a7672777f0ed15692ae2ba47838208537558.zip
Update dependencies (#1929)
Diffstat (limited to 'vendor/modernc.org/cc/v3/check.go')
-rw-r--r--vendor/modernc.org/cc/v3/check.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/vendor/modernc.org/cc/v3/check.go b/vendor/modernc.org/cc/v3/check.go
index 50887870..a523760f 100644
--- a/vendor/modernc.org/cc/v3/check.go
+++ b/vendor/modernc.org/cc/v3/check.go
@@ -1138,6 +1138,10 @@ func (n *UnaryExpression) check(ctx *context, isAsmArg bool) Operand {
case UnaryExpressionPlus: // '+' CastExpression
op := n.CastExpression.check(ctx, isAsmArg)
n.IsSideEffectsFree = n.CastExpression.IsSideEffectsFree
+ if op == nil {
+ //TODO report error
+ break
+ }
if !op.Type().IsArithmeticType() {
//TODO report error
break
@@ -1150,6 +1154,10 @@ func (n *UnaryExpression) check(ctx *context, isAsmArg bool) Operand {
case UnaryExpressionMinus: // '-' CastExpression
op := n.CastExpression.check(ctx, isAsmArg)
n.IsSideEffectsFree = n.CastExpression.IsSideEffectsFree
+ if op == nil {
+ //TODO report error
+ break
+ }
if op.Type().Kind() == Vector {
n.Operand = &operand{abi: &ctx.cfg.ABI, typ: op.Type()}
break