Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • sac2c sac2c
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 400
    • Issues 400
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • External wiki
    • External wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • sac-group
  • sac2csac2c
  • Issues
  • #1444
Closed
Open
Created Apr 24, 2007 by Robert Bernecky@rbeDeveloper

DCR doesn't remove dead parameters from functions

Bugzilla Link 355
Created on Apr 24, 2007 19:35
Resolution INVALID
Resolved on Apr 25, 2007 08:36
Version 1.00beta
OS Linux
Architecture PC

Extended Description

Summary says it all. I expected that some phase or another of sac2c would
remove the dead variable "junk" from the function prototype and call of foo.
However, this does not seem to be the case.
use Array: all;
use StdIO: all;
int[*] id(int[*] x)
{ return(x);
}
int[*] foo (int[*]x, int[*] junk2)
{
 return(x*10);
}
int main()
{
 junk = id(23);
 x = iota(id(55));
 z = foo(x,junk);
 print(z);
 return(1);
}
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking