default:
yyerror("defaultlit: unknown literal: %v", n)
}
+ lineno = lno
+ return n
case CTxxx:
Fatalf("defaultlit: idealkind is CTxxx: %+v", n)
t1 = t
}
n = convlit1(n, t1, false, reuse)
+ lineno = lno
+ return n
case CTINT:
t1 = types.Types[TINT]
- goto num
-
case CTRUNE:
t1 = types.Runetype
- goto num
-
case CTFLT:
t1 = types.Types[TFLOAT64]
- goto num
-
case CTCPLX:
t1 = types.Types[TCOMPLEX128]
- goto num
}
- lineno = lno
- return n
-
-num:
// Note: n.Val().Ctype() can be CTxxx (not a constant) here
// in the case of an untyped non-constant value, like 1<<i.
v1 := n.Val()
case OCONV, OCONVNOP:
if thearch.SoftFloat {
// For the soft-float case, ssa.go handles these conversions.
- goto oconv_walkexpr
+ n.Left = walkexpr(n.Left, init)
+ break
}
switch thearch.LinkArch.Family {
case sys.ARM, sys.MIPS:
}
}
}
-
- oconv_walkexpr:
n.Left = walkexpr(n.Left, init)
case OANDNOT:
case obj.NAME_NONE:
c.instoffset = a.Offset
if a.Reg != 0 && a.Reg != REGZERO {
- goto aconsize
+ break
}
v := c.instoffset
if v == 0 {
case obj.NAME_EXTERN, obj.NAME_STATIC:
if a.Sym == nil {
- break
+ return C_GOK
}
if a.Sym.Type == objabi.STLSBSS {
c.ctxt.Diag("taking address of TLS variable is not supported")
a.Reg = obj.REG_NONE
}
c.instoffset = int64(c.autosize) + a.Offset
- goto aconsize
case obj.NAME_PARAM:
if a.Reg == REGSP {
a.Reg = obj.REG_NONE
}
c.instoffset = int64(c.autosize) + a.Offset + 8
- goto aconsize
+ default:
+ return C_GOK
}
- return C_GOK
- aconsize:
if isaddcon(c.instoffset) {
return C_AACON
}
return C_DACON
}
- goto consize
-
case obj.NAME_EXTERN,
obj.NAME_STATIC:
s := a.Sym
if s == nil {
- break
+ return C_GOK
}
c.instoffset = a.Offset
return C_SACON
}
return C_LACON
- }
- return C_GOK
+ default:
+ return C_GOK
+ }
- consize:
if c.instoffset >= 0 {
if c.instoffset == 0 {
return C_ZCON
t = sch[j:]
if t[0].comp {
if s[0].p.Mark&BRANCH != 0 {
- goto no2
+ continue
}
}
if t[0].p.Mark&DELAY != 0 {
if -cap(s) >= -cap(se) || conflict(&t[0], &s[1]) {
- goto no2
+ continue
}
}
for u := t[1:]; -cap(u) <= -cap(s); u = u[1:] {
if c.depend(&u[0], &t[0]) {
- goto no2
+ continue
}
}
goto out2
- no2:
}
if s[0].p.Mark&BRANCH != 0 {
return C_DACON
}
- goto consize
-
case obj.NAME_EXTERN,
obj.NAME_STATIC:
s := a.Sym
if s == nil {
- break
+ return C_GOK
}
c.instoffset = a.Offset
return C_SACON
}
return C_LACON
- }
- return C_GOK
+ default:
+ return C_GOK
+ }
- consize:
if c.instoffset >= 0 {
if c.instoffset == 0 {
return C_ZCON
}
return C_DACON
}
- goto consize
case obj.NAME_EXTERN,
obj.NAME_STATIC:
s := a.Sym
if s == nil {
- break
+ return C_GOK
}
c.instoffset = a.Offset
return C_SACON
}
return C_LACON
- }
- return C_GOK
+ default:
+ return C_GOK
+ }
- consize:
if c.instoffset == 0 {
return C_ZCON
}