Accessing a static var on a datum assigned to proc var doesn't mark the var as used, causing a var defined but not used warning if no non-static vars are used
Code Snippet (if applicable) to Reproduce Problem:
datum
testdatum5
var/static/var1 = 0
mob
proc/testcompilewarningbug()
var/datum/testdatum5/D = new()
D.var1 += 1
. += D.var1
Expected Results:
nothing
Actual Results:
warning: D: variable defined but not used
(Confirmed in 510 as well)