We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c96fdf0 commit e60c04fCopy full SHA for e60c04f
1 file changed
pcbasic/basic/memory/memory.py
@@ -515,6 +515,10 @@ def varptr_(self, args):
515
name = arg0
516
error.throw_if(not name, error.STX)
517
indices, = args
518
+ name = self.complete_name(name)
519
+ if indices != []:
520
+ # pre-allocate array elements, but not scalars which instead throw IFC if undefined
521
+ self.arrays.check_dim(name, indices)
522
var_ptr = self.varptr(name, indices)
523
return self.values.new_integer().from_int(var_ptr, unsigned=True)
524
@@ -524,6 +528,7 @@ def varptr_str_(self, args):
528
525
529
indices = next(args)
526
530
list(args)
531
527
532
if indices != []:
533
# pre-allocate array elements, but not scalars which instead throw IFC if undefined
534
self.arrays.check_dim(name, indices)
0 commit comments