summary refs log blame commit diff stats
path: root/tests/ccgbugs/tprogmem.nim
blob: 884ca158abcbc9f8f8883e89a186a61afa3e5ea4 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11










                                                                           
discard """
  output: "5"
  cmd: r"nim c --hints:on $options -d:release $file"
  ccodecheck: "'/*PROGMEM*/ myLetVariable = {'"
  target: "C"
"""

var myLetVariable {.exportc, codegenDecl: "$# /*PROGMEM*/ $#".} = [1, 2, 3]

myLetVariable[0] = 5
echo myLetVariable[0]