mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-19 08:38:14 +01:00
Propagate const-values to idents of consts
This commit is contained in:
1 parent
9f6c40246f
commit
1f424b2ea7
3 files changed
+39
-49
No files matched your search
@@ -370,6 +370,7 @@ func (q *checker) tcheckExprOther(n *a.Expr, depth uint32) error {
|
||||
// TODO: check somewhere that a global ident (i.e. a const) is
|
||||
// not directly in the LHS of an assignment.
|
||||
n.SetGlobalIdent()
|
||||
n.SetConstValue(c.Value().ConstValue())
|
||||
n.SetMType(c.XType())
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user