Skip to content
This repository has been archived by the owner on May 21, 2024. It is now read-only.

Commit

Permalink
Merge pull request boriel-basic#267 from boriel/bugfix/warn_msg_unuse…
Browse files Browse the repository at this point in the history
…d_byreg_param

Fix warning message in byref params
  • Loading branch information
boriel committed Apr 4, 2020
2 parents ed38958 + fdf2863 commit abde313
Show file tree
Hide file tree
Showing 4 changed files with 1,721 additions and 1 deletion.
3 changes: 2 additions & 1 deletion api/symboltable.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,8 @@ def entry_size(entry):
if v.scope == SCOPE.parameter:
kind = 'Parameter'
v.accessed = True # HINT: Parameters must always be present even if not used!
warning_not_used(v.lineno, v.name, kind=kind)
if not v.byref: # HINT: byref is always marked as used: it can be used to return a value
warning_not_used(v.lineno, v.name, kind=kind)

entries = sorted(self.table[self.current_scope].values(filter_by_opt=True), key=entry_size)
offset = 0
Expand Down

0 comments on commit abde313

Please sign in to comment.