doctrine / doctrine/common

DCOM-307: Create a "Code Inliner" component for inlining function calls

Open
#621 2 comments 0 reactions 1 assignee Claimed by @Ocramius View on GitHub
New Feature
Dominant language
PHP
Stars
5.8k
Forks
284
PR merge metrics
No merged PRs in 30d

Description

Jira issue originally created by user @ocramius:

Given following pieces of code:

```
function baz($tab) {
$taz;
}
function foo () {
return baz('tab');
}

echo foo();
```

we want to have a simple (safe - must bail out eagerly) code-inliner that produces following:

```
$foo*generated*tab = 'tab';
echo $foo*generated*tab;
```

This sort of code generator/inliner would be useful to simplify generated hydrators

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.